<?php
//红头呀
class DuckRed implements DuckInterface, QuickObservable {
    protected $name = "红头鸭子";
    protected $observe;
    public function __construct()
    {
        $this->observe = new Observable($this);
    }

    public function quick()
    {
        echo $this->name."  叫了<br>";
        $this->notify();
    }
    public function notify()
    {
        $this->observe->notify();
    }
    public function register(Observe $ob)
    {
       $this->observe->register($ob);
    }
    public function getName()
    {
        return $this->name;
    }
}